#pragma once
// MESSAGE GNSS_DATA PACKING

#define MAVLINK_MSG_ID_GNSS_DATA 33

MAVPACKED(
typedef struct __mavlink_gnss_data_t {
 uint64_t time; /*<  time.*/
 uint32_t dt; /*<  dt.*/
 float lon; /*<  longitude.*/
 float lat; /*<  latitude.*/
 float height; /*<  height.*/
 float east; /*<  east.*/
 float north; /*<  north.*/
 float up; /*<  up.*/
 float eastVel; /*<  eastVel.*/
 float northVel; /*<  northVel.*/
 float upVel; /*<  upVel.*/
 float heading; /*<  heading.*/
 float pitch; /*<  pitch.*/
 float tracktrue; /*<  tracktrue.*/
 float vel; /*<  vel.*/
 float roll; /*<  roll.*/
 int32_t pos_qual; /*<  pos_qual.*/
 int32_t heading_qual; /*<  heading_qual.*/
 int32_t satNum1; /*<  satNum1.*/
 int32_t satNum2; /*<  satNum2.*/
 int32_t gps_Num; /*<  gps_num.*/
 int32_t bds_Num; /*<  gps_num.*/
 int32_t glo_Num; /*<  gps_num.*/
 float pdop; /*<  pdop (0.5..99.9).*/
 float hdop; /*<   hdop (0.5..99.9).*/
 float vdop; /*<   vdop (0.5..99.9).*/
 float data1; /*<  data1*/
 float data2; /*<  data2*/
 float data3; /*<  data3*/
 float data4; /*<  data4*/
 float data5; /*<  data5*/
 float data6; /*<  data6*/
 float data7; /*<  data7*/
 float data8; /*<  data8*/
 float data9; /*<  data9*/
 float data10; /*<  data10*/
 uint8_t year; /*<   component.*/
 uint8_t month; /*<   component.*/
 uint8_t day; /*<   component.*/
 uint8_t hour; /*<   component.*/
 uint8_t minute; /*<   component.*/
 uint8_t second; /*<   component.*/
}) mavlink_gnss_data_t;

#define MAVLINK_MSG_ID_GNSS_DATA_LEN 154
#define MAVLINK_MSG_ID_GNSS_DATA_MIN_LEN 154
#define MAVLINK_MSG_ID_33_LEN 154
#define MAVLINK_MSG_ID_33_MIN_LEN 154

#define MAVLINK_MSG_ID_GNSS_DATA_CRC 169
#define MAVLINK_MSG_ID_33_CRC 169



#if MAVLINK_COMMAND_24BIT
#define MAVLINK_MESSAGE_INFO_GNSS_DATA { \
    33, \
    "GNSS_DATA", \
    42, \
    {  { "time", NULL, MAVLINK_TYPE_UINT64_T, 0, 0, offsetof(mavlink_gnss_data_t, time) }, \
         { "dt", NULL, MAVLINK_TYPE_UINT32_T, 0, 8, offsetof(mavlink_gnss_data_t, dt) }, \
         { "lon", NULL, MAVLINK_TYPE_FLOAT, 0, 12, offsetof(mavlink_gnss_data_t, lon) }, \
         { "lat", NULL, MAVLINK_TYPE_FLOAT, 0, 16, offsetof(mavlink_gnss_data_t, lat) }, \
         { "height", NULL, MAVLINK_TYPE_FLOAT, 0, 20, offsetof(mavlink_gnss_data_t, height) }, \
         { "east", NULL, MAVLINK_TYPE_FLOAT, 0, 24, offsetof(mavlink_gnss_data_t, east) }, \
         { "north", NULL, MAVLINK_TYPE_FLOAT, 0, 28, offsetof(mavlink_gnss_data_t, north) }, \
         { "up", NULL, MAVLINK_TYPE_FLOAT, 0, 32, offsetof(mavlink_gnss_data_t, up) }, \
         { "eastVel", NULL, MAVLINK_TYPE_FLOAT, 0, 36, offsetof(mavlink_gnss_data_t, eastVel) }, \
         { "northVel", NULL, MAVLINK_TYPE_FLOAT, 0, 40, offsetof(mavlink_gnss_data_t, northVel) }, \
         { "upVel", NULL, MAVLINK_TYPE_FLOAT, 0, 44, offsetof(mavlink_gnss_data_t, upVel) }, \
         { "heading", NULL, MAVLINK_TYPE_FLOAT, 0, 48, offsetof(mavlink_gnss_data_t, heading) }, \
         { "pitch", NULL, MAVLINK_TYPE_FLOAT, 0, 52, offsetof(mavlink_gnss_data_t, pitch) }, \
         { "tracktrue", NULL, MAVLINK_TYPE_FLOAT, 0, 56, offsetof(mavlink_gnss_data_t, tracktrue) }, \
         { "vel", NULL, MAVLINK_TYPE_FLOAT, 0, 60, offsetof(mavlink_gnss_data_t, vel) }, \
         { "roll", NULL, MAVLINK_TYPE_FLOAT, 0, 64, offsetof(mavlink_gnss_data_t, roll) }, \
         { "pos_qual", NULL, MAVLINK_TYPE_INT32_T, 0, 68, offsetof(mavlink_gnss_data_t, pos_qual) }, \
         { "heading_qual", NULL, MAVLINK_TYPE_INT32_T, 0, 72, offsetof(mavlink_gnss_data_t, heading_qual) }, \
         { "satNum1", NULL, MAVLINK_TYPE_INT32_T, 0, 76, offsetof(mavlink_gnss_data_t, satNum1) }, \
         { "satNum2", NULL, MAVLINK_TYPE_INT32_T, 0, 80, offsetof(mavlink_gnss_data_t, satNum2) }, \
         { "gps_Num", NULL, MAVLINK_TYPE_INT32_T, 0, 84, offsetof(mavlink_gnss_data_t, gps_Num) }, \
         { "bds_Num", NULL, MAVLINK_TYPE_INT32_T, 0, 88, offsetof(mavlink_gnss_data_t, bds_Num) }, \
         { "glo_Num", NULL, MAVLINK_TYPE_INT32_T, 0, 92, offsetof(mavlink_gnss_data_t, glo_Num) }, \
         { "pdop", NULL, MAVLINK_TYPE_FLOAT, 0, 96, offsetof(mavlink_gnss_data_t, pdop) }, \
         { "hdop", NULL, MAVLINK_TYPE_FLOAT, 0, 100, offsetof(mavlink_gnss_data_t, hdop) }, \
         { "vdop", NULL, MAVLINK_TYPE_FLOAT, 0, 104, offsetof(mavlink_gnss_data_t, vdop) }, \
         { "year", NULL, MAVLINK_TYPE_UINT8_T, 0, 148, offsetof(mavlink_gnss_data_t, year) }, \
         { "month", NULL, MAVLINK_TYPE_UINT8_T, 0, 149, offsetof(mavlink_gnss_data_t, month) }, \
         { "day", NULL, MAVLINK_TYPE_UINT8_T, 0, 150, offsetof(mavlink_gnss_data_t, day) }, \
         { "hour", NULL, MAVLINK_TYPE_UINT8_T, 0, 151, offsetof(mavlink_gnss_data_t, hour) }, \
         { "minute", NULL, MAVLINK_TYPE_UINT8_T, 0, 152, offsetof(mavlink_gnss_data_t, minute) }, \
         { "second", NULL, MAVLINK_TYPE_UINT8_T, 0, 153, offsetof(mavlink_gnss_data_t, second) }, \
         { "data1", NULL, MAVLINK_TYPE_FLOAT, 0, 108, offsetof(mavlink_gnss_data_t, data1) }, \
         { "data2", NULL, MAVLINK_TYPE_FLOAT, 0, 112, offsetof(mavlink_gnss_data_t, data2) }, \
         { "data3", NULL, MAVLINK_TYPE_FLOAT, 0, 116, offsetof(mavlink_gnss_data_t, data3) }, \
         { "data4", NULL, MAVLINK_TYPE_FLOAT, 0, 120, offsetof(mavlink_gnss_data_t, data4) }, \
         { "data5", NULL, MAVLINK_TYPE_FLOAT, 0, 124, offsetof(mavlink_gnss_data_t, data5) }, \
         { "data6", NULL, MAVLINK_TYPE_FLOAT, 0, 128, offsetof(mavlink_gnss_data_t, data6) }, \
         { "data7", NULL, MAVLINK_TYPE_FLOAT, 0, 132, offsetof(mavlink_gnss_data_t, data7) }, \
         { "data8", NULL, MAVLINK_TYPE_FLOAT, 0, 136, offsetof(mavlink_gnss_data_t, data8) }, \
         { "data9", NULL, MAVLINK_TYPE_FLOAT, 0, 140, offsetof(mavlink_gnss_data_t, data9) }, \
         { "data10", NULL, MAVLINK_TYPE_FLOAT, 0, 144, offsetof(mavlink_gnss_data_t, data10) }, \
         } \
}
#else
#define MAVLINK_MESSAGE_INFO_GNSS_DATA { \
    "GNSS_DATA", \
    42, \
    {  { "time", NULL, MAVLINK_TYPE_UINT64_T, 0, 0, offsetof(mavlink_gnss_data_t, time) }, \
         { "dt", NULL, MAVLINK_TYPE_UINT32_T, 0, 8, offsetof(mavlink_gnss_data_t, dt) }, \
         { "lon", NULL, MAVLINK_TYPE_FLOAT, 0, 12, offsetof(mavlink_gnss_data_t, lon) }, \
         { "lat", NULL, MAVLINK_TYPE_FLOAT, 0, 16, offsetof(mavlink_gnss_data_t, lat) }, \
         { "height", NULL, MAVLINK_TYPE_FLOAT, 0, 20, offsetof(mavlink_gnss_data_t, height) }, \
         { "east", NULL, MAVLINK_TYPE_FLOAT, 0, 24, offsetof(mavlink_gnss_data_t, east) }, \
         { "north", NULL, MAVLINK_TYPE_FLOAT, 0, 28, offsetof(mavlink_gnss_data_t, north) }, \
         { "up", NULL, MAVLINK_TYPE_FLOAT, 0, 32, offsetof(mavlink_gnss_data_t, up) }, \
         { "eastVel", NULL, MAVLINK_TYPE_FLOAT, 0, 36, offsetof(mavlink_gnss_data_t, eastVel) }, \
         { "northVel", NULL, MAVLINK_TYPE_FLOAT, 0, 40, offsetof(mavlink_gnss_data_t, northVel) }, \
         { "upVel", NULL, MAVLINK_TYPE_FLOAT, 0, 44, offsetof(mavlink_gnss_data_t, upVel) }, \
         { "heading", NULL, MAVLINK_TYPE_FLOAT, 0, 48, offsetof(mavlink_gnss_data_t, heading) }, \
         { "pitch", NULL, MAVLINK_TYPE_FLOAT, 0, 52, offsetof(mavlink_gnss_data_t, pitch) }, \
         { "tracktrue", NULL, MAVLINK_TYPE_FLOAT, 0, 56, offsetof(mavlink_gnss_data_t, tracktrue) }, \
         { "vel", NULL, MAVLINK_TYPE_FLOAT, 0, 60, offsetof(mavlink_gnss_data_t, vel) }, \
         { "roll", NULL, MAVLINK_TYPE_FLOAT, 0, 64, offsetof(mavlink_gnss_data_t, roll) }, \
         { "pos_qual", NULL, MAVLINK_TYPE_INT32_T, 0, 68, offsetof(mavlink_gnss_data_t, pos_qual) }, \
         { "heading_qual", NULL, MAVLINK_TYPE_INT32_T, 0, 72, offsetof(mavlink_gnss_data_t, heading_qual) }, \
         { "satNum1", NULL, MAVLINK_TYPE_INT32_T, 0, 76, offsetof(mavlink_gnss_data_t, satNum1) }, \
         { "satNum2", NULL, MAVLINK_TYPE_INT32_T, 0, 80, offsetof(mavlink_gnss_data_t, satNum2) }, \
         { "gps_Num", NULL, MAVLINK_TYPE_INT32_T, 0, 84, offsetof(mavlink_gnss_data_t, gps_Num) }, \
         { "bds_Num", NULL, MAVLINK_TYPE_INT32_T, 0, 88, offsetof(mavlink_gnss_data_t, bds_Num) }, \
         { "glo_Num", NULL, MAVLINK_TYPE_INT32_T, 0, 92, offsetof(mavlink_gnss_data_t, glo_Num) }, \
         { "pdop", NULL, MAVLINK_TYPE_FLOAT, 0, 96, offsetof(mavlink_gnss_data_t, pdop) }, \
         { "hdop", NULL, MAVLINK_TYPE_FLOAT, 0, 100, offsetof(mavlink_gnss_data_t, hdop) }, \
         { "vdop", NULL, MAVLINK_TYPE_FLOAT, 0, 104, offsetof(mavlink_gnss_data_t, vdop) }, \
         { "year", NULL, MAVLINK_TYPE_UINT8_T, 0, 148, offsetof(mavlink_gnss_data_t, year) }, \
         { "month", NULL, MAVLINK_TYPE_UINT8_T, 0, 149, offsetof(mavlink_gnss_data_t, month) }, \
         { "day", NULL, MAVLINK_TYPE_UINT8_T, 0, 150, offsetof(mavlink_gnss_data_t, day) }, \
         { "hour", NULL, MAVLINK_TYPE_UINT8_T, 0, 151, offsetof(mavlink_gnss_data_t, hour) }, \
         { "minute", NULL, MAVLINK_TYPE_UINT8_T, 0, 152, offsetof(mavlink_gnss_data_t, minute) }, \
         { "second", NULL, MAVLINK_TYPE_UINT8_T, 0, 153, offsetof(mavlink_gnss_data_t, second) }, \
         { "data1", NULL, MAVLINK_TYPE_FLOAT, 0, 108, offsetof(mavlink_gnss_data_t, data1) }, \
         { "data2", NULL, MAVLINK_TYPE_FLOAT, 0, 112, offsetof(mavlink_gnss_data_t, data2) }, \
         { "data3", NULL, MAVLINK_TYPE_FLOAT, 0, 116, offsetof(mavlink_gnss_data_t, data3) }, \
         { "data4", NULL, MAVLINK_TYPE_FLOAT, 0, 120, offsetof(mavlink_gnss_data_t, data4) }, \
         { "data5", NULL, MAVLINK_TYPE_FLOAT, 0, 124, offsetof(mavlink_gnss_data_t, data5) }, \
         { "data6", NULL, MAVLINK_TYPE_FLOAT, 0, 128, offsetof(mavlink_gnss_data_t, data6) }, \
         { "data7", NULL, MAVLINK_TYPE_FLOAT, 0, 132, offsetof(mavlink_gnss_data_t, data7) }, \
         { "data8", NULL, MAVLINK_TYPE_FLOAT, 0, 136, offsetof(mavlink_gnss_data_t, data8) }, \
         { "data9", NULL, MAVLINK_TYPE_FLOAT, 0, 140, offsetof(mavlink_gnss_data_t, data9) }, \
         { "data10", NULL, MAVLINK_TYPE_FLOAT, 0, 144, offsetof(mavlink_gnss_data_t, data10) }, \
         } \
}
#endif

/**
 * @brief Pack a gnss_data message
 * @param system_id ID of this system
 * @param component_id ID of this component (e.g. 200 for IMU)
 * @param msg The MAVLink message to compress the data into
 *
 * @param time  time.
 * @param dt  dt.
 * @param lon  longitude.
 * @param lat  latitude.
 * @param height  height.
 * @param east  east.
 * @param north  north.
 * @param up  up.
 * @param eastVel  eastVel.
 * @param northVel  northVel.
 * @param upVel  upVel.
 * @param heading  heading.
 * @param pitch  pitch.
 * @param tracktrue  tracktrue.
 * @param vel  vel.
 * @param roll  roll.
 * @param pos_qual  pos_qual.
 * @param heading_qual  heading_qual.
 * @param satNum1  satNum1.
 * @param satNum2  satNum2.
 * @param gps_Num  gps_num.
 * @param bds_Num  gps_num.
 * @param glo_Num  gps_num.
 * @param pdop  pdop (0.5..99.9).
 * @param hdop   hdop (0.5..99.9).
 * @param vdop   vdop (0.5..99.9).
 * @param year   component.
 * @param month   component.
 * @param day   component.
 * @param hour   component.
 * @param minute   component.
 * @param second   component.
 * @param data1  data1
 * @param data2  data2
 * @param data3  data3
 * @param data4  data4
 * @param data5  data5
 * @param data6  data6
 * @param data7  data7
 * @param data8  data8
 * @param data9  data9
 * @param data10  data10
 * @return length of the message in bytes (excluding serial stream start sign)
 */
static inline uint16_t mavlink_msg_gnss_data_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
                               uint64_t time, uint32_t dt, float lon, float lat, float height, float east, float north, float up, float eastVel, float northVel, float upVel, float heading, float pitch, float tracktrue, float vel, float roll, int32_t pos_qual, int32_t heading_qual, int32_t satNum1, int32_t satNum2, int32_t gps_Num, int32_t bds_Num, int32_t glo_Num, float pdop, float hdop, float vdop, uint8_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second, float data1, float data2, float data3, float data4, float data5, float data6, float data7, float data8, float data9, float data10)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
    char buf[MAVLINK_MSG_ID_GNSS_DATA_LEN];
    _mav_put_uint64_t(buf, 0, time);
    _mav_put_uint32_t(buf, 8, dt);
    _mav_put_float(buf, 12, lon);
    _mav_put_float(buf, 16, lat);
    _mav_put_float(buf, 20, height);
    _mav_put_float(buf, 24, east);
    _mav_put_float(buf, 28, north);
    _mav_put_float(buf, 32, up);
    _mav_put_float(buf, 36, eastVel);
    _mav_put_float(buf, 40, northVel);
    _mav_put_float(buf, 44, upVel);
    _mav_put_float(buf, 48, heading);
    _mav_put_float(buf, 52, pitch);
    _mav_put_float(buf, 56, tracktrue);
    _mav_put_float(buf, 60, vel);
    _mav_put_float(buf, 64, roll);
    _mav_put_int32_t(buf, 68, pos_qual);
    _mav_put_int32_t(buf, 72, heading_qual);
    _mav_put_int32_t(buf, 76, satNum1);
    _mav_put_int32_t(buf, 80, satNum2);
    _mav_put_int32_t(buf, 84, gps_Num);
    _mav_put_int32_t(buf, 88, bds_Num);
    _mav_put_int32_t(buf, 92, glo_Num);
    _mav_put_float(buf, 96, pdop);
    _mav_put_float(buf, 100, hdop);
    _mav_put_float(buf, 104, vdop);
    _mav_put_float(buf, 108, data1);
    _mav_put_float(buf, 112, data2);
    _mav_put_float(buf, 116, data3);
    _mav_put_float(buf, 120, data4);
    _mav_put_float(buf, 124, data5);
    _mav_put_float(buf, 128, data6);
    _mav_put_float(buf, 132, data7);
    _mav_put_float(buf, 136, data8);
    _mav_put_float(buf, 140, data9);
    _mav_put_float(buf, 144, data10);
    _mav_put_uint8_t(buf, 148, year);
    _mav_put_uint8_t(buf, 149, month);
    _mav_put_uint8_t(buf, 150, day);
    _mav_put_uint8_t(buf, 151, hour);
    _mav_put_uint8_t(buf, 152, minute);
    _mav_put_uint8_t(buf, 153, second);

        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GNSS_DATA_LEN);
#else
    mavlink_gnss_data_t packet;
    packet.time = time;
    packet.dt = dt;
    packet.lon = lon;
    packet.lat = lat;
    packet.height = height;
    packet.east = east;
    packet.north = north;
    packet.up = up;
    packet.eastVel = eastVel;
    packet.northVel = northVel;
    packet.upVel = upVel;
    packet.heading = heading;
    packet.pitch = pitch;
    packet.tracktrue = tracktrue;
    packet.vel = vel;
    packet.roll = roll;
    packet.pos_qual = pos_qual;
    packet.heading_qual = heading_qual;
    packet.satNum1 = satNum1;
    packet.satNum2 = satNum2;
    packet.gps_Num = gps_Num;
    packet.bds_Num = bds_Num;
    packet.glo_Num = glo_Num;
    packet.pdop = pdop;
    packet.hdop = hdop;
    packet.vdop = vdop;
    packet.data1 = data1;
    packet.data2 = data2;
    packet.data3 = data3;
    packet.data4 = data4;
    packet.data5 = data5;
    packet.data6 = data6;
    packet.data7 = data7;
    packet.data8 = data8;
    packet.data9 = data9;
    packet.data10 = data10;
    packet.year = year;
    packet.month = month;
    packet.day = day;
    packet.hour = hour;
    packet.minute = minute;
    packet.second = second;

        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GNSS_DATA_LEN);
#endif

    msg->msgid = MAVLINK_MSG_ID_GNSS_DATA;
    return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GNSS_DATA_MIN_LEN, MAVLINK_MSG_ID_GNSS_DATA_LEN, MAVLINK_MSG_ID_GNSS_DATA_CRC);
}

/**
 * @brief Pack a gnss_data message on a channel
 * @param system_id ID of this system
 * @param component_id ID of this component (e.g. 200 for IMU)
 * @param chan The MAVLink channel this message will be sent over
 * @param msg The MAVLink message to compress the data into
 * @param time  time.
 * @param dt  dt.
 * @param lon  longitude.
 * @param lat  latitude.
 * @param height  height.
 * @param east  east.
 * @param north  north.
 * @param up  up.
 * @param eastVel  eastVel.
 * @param northVel  northVel.
 * @param upVel  upVel.
 * @param heading  heading.
 * @param pitch  pitch.
 * @param tracktrue  tracktrue.
 * @param vel  vel.
 * @param roll  roll.
 * @param pos_qual  pos_qual.
 * @param heading_qual  heading_qual.
 * @param satNum1  satNum1.
 * @param satNum2  satNum2.
 * @param gps_Num  gps_num.
 * @param bds_Num  gps_num.
 * @param glo_Num  gps_num.
 * @param pdop  pdop (0.5..99.9).
 * @param hdop   hdop (0.5..99.9).
 * @param vdop   vdop (0.5..99.9).
 * @param year   component.
 * @param month   component.
 * @param day   component.
 * @param hour   component.
 * @param minute   component.
 * @param second   component.
 * @param data1  data1
 * @param data2  data2
 * @param data3  data3
 * @param data4  data4
 * @param data5  data5
 * @param data6  data6
 * @param data7  data7
 * @param data8  data8
 * @param data9  data9
 * @param data10  data10
 * @return length of the message in bytes (excluding serial stream start sign)
 */
static inline uint16_t mavlink_msg_gnss_data_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
                               mavlink_message_t* msg,
                                   uint64_t time,uint32_t dt,float lon,float lat,float height,float east,float north,float up,float eastVel,float northVel,float upVel,float heading,float pitch,float tracktrue,float vel,float roll,int32_t pos_qual,int32_t heading_qual,int32_t satNum1,int32_t satNum2,int32_t gps_Num,int32_t bds_Num,int32_t glo_Num,float pdop,float hdop,float vdop,uint8_t year,uint8_t month,uint8_t day,uint8_t hour,uint8_t minute,uint8_t second,float data1,float data2,float data3,float data4,float data5,float data6,float data7,float data8,float data9,float data10)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
    char buf[MAVLINK_MSG_ID_GNSS_DATA_LEN];
    _mav_put_uint64_t(buf, 0, time);
    _mav_put_uint32_t(buf, 8, dt);
    _mav_put_float(buf, 12, lon);
    _mav_put_float(buf, 16, lat);
    _mav_put_float(buf, 20, height);
    _mav_put_float(buf, 24, east);
    _mav_put_float(buf, 28, north);
    _mav_put_float(buf, 32, up);
    _mav_put_float(buf, 36, eastVel);
    _mav_put_float(buf, 40, northVel);
    _mav_put_float(buf, 44, upVel);
    _mav_put_float(buf, 48, heading);
    _mav_put_float(buf, 52, pitch);
    _mav_put_float(buf, 56, tracktrue);
    _mav_put_float(buf, 60, vel);
    _mav_put_float(buf, 64, roll);
    _mav_put_int32_t(buf, 68, pos_qual);
    _mav_put_int32_t(buf, 72, heading_qual);
    _mav_put_int32_t(buf, 76, satNum1);
    _mav_put_int32_t(buf, 80, satNum2);
    _mav_put_int32_t(buf, 84, gps_Num);
    _mav_put_int32_t(buf, 88, bds_Num);
    _mav_put_int32_t(buf, 92, glo_Num);
    _mav_put_float(buf, 96, pdop);
    _mav_put_float(buf, 100, hdop);
    _mav_put_float(buf, 104, vdop);
    _mav_put_float(buf, 108, data1);
    _mav_put_float(buf, 112, data2);
    _mav_put_float(buf, 116, data3);
    _mav_put_float(buf, 120, data4);
    _mav_put_float(buf, 124, data5);
    _mav_put_float(buf, 128, data6);
    _mav_put_float(buf, 132, data7);
    _mav_put_float(buf, 136, data8);
    _mav_put_float(buf, 140, data9);
    _mav_put_float(buf, 144, data10);
    _mav_put_uint8_t(buf, 148, year);
    _mav_put_uint8_t(buf, 149, month);
    _mav_put_uint8_t(buf, 150, day);
    _mav_put_uint8_t(buf, 151, hour);
    _mav_put_uint8_t(buf, 152, minute);
    _mav_put_uint8_t(buf, 153, second);

        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GNSS_DATA_LEN);
#else
    mavlink_gnss_data_t packet;
    packet.time = time;
    packet.dt = dt;
    packet.lon = lon;
    packet.lat = lat;
    packet.height = height;
    packet.east = east;
    packet.north = north;
    packet.up = up;
    packet.eastVel = eastVel;
    packet.northVel = northVel;
    packet.upVel = upVel;
    packet.heading = heading;
    packet.pitch = pitch;
    packet.tracktrue = tracktrue;
    packet.vel = vel;
    packet.roll = roll;
    packet.pos_qual = pos_qual;
    packet.heading_qual = heading_qual;
    packet.satNum1 = satNum1;
    packet.satNum2 = satNum2;
    packet.gps_Num = gps_Num;
    packet.bds_Num = bds_Num;
    packet.glo_Num = glo_Num;
    packet.pdop = pdop;
    packet.hdop = hdop;
    packet.vdop = vdop;
    packet.data1 = data1;
    packet.data2 = data2;
    packet.data3 = data3;
    packet.data4 = data4;
    packet.data5 = data5;
    packet.data6 = data6;
    packet.data7 = data7;
    packet.data8 = data8;
    packet.data9 = data9;
    packet.data10 = data10;
    packet.year = year;
    packet.month = month;
    packet.day = day;
    packet.hour = hour;
    packet.minute = minute;
    packet.second = second;

        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GNSS_DATA_LEN);
#endif

    msg->msgid = MAVLINK_MSG_ID_GNSS_DATA;
    return mavlink_finalize_message_chan(msg, system_id, component_id, chan, MAVLINK_MSG_ID_GNSS_DATA_MIN_LEN, MAVLINK_MSG_ID_GNSS_DATA_LEN, MAVLINK_MSG_ID_GNSS_DATA_CRC);
}

/**
 * @brief Encode a gnss_data struct
 *
 * @param system_id ID of this system
 * @param component_id ID of this component (e.g. 200 for IMU)
 * @param msg The MAVLink message to compress the data into
 * @param gnss_data C-struct to read the message contents from
 */
static inline uint16_t mavlink_msg_gnss_data_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg, const mavlink_gnss_data_t* gnss_data)
{
    return mavlink_msg_gnss_data_pack(system_id, component_id, msg, gnss_data->time, gnss_data->dt, gnss_data->lon, gnss_data->lat, gnss_data->height, gnss_data->east, gnss_data->north, gnss_data->up, gnss_data->eastVel, gnss_data->northVel, gnss_data->upVel, gnss_data->heading, gnss_data->pitch, gnss_data->tracktrue, gnss_data->vel, gnss_data->roll, gnss_data->pos_qual, gnss_data->heading_qual, gnss_data->satNum1, gnss_data->satNum2, gnss_data->gps_Num, gnss_data->bds_Num, gnss_data->glo_Num, gnss_data->pdop, gnss_data->hdop, gnss_data->vdop, gnss_data->year, gnss_data->month, gnss_data->day, gnss_data->hour, gnss_data->minute, gnss_data->second, gnss_data->data1, gnss_data->data2, gnss_data->data3, gnss_data->data4, gnss_data->data5, gnss_data->data6, gnss_data->data7, gnss_data->data8, gnss_data->data9, gnss_data->data10);
}

/**
 * @brief Encode a gnss_data struct on a channel
 *
 * @param system_id ID of this system
 * @param component_id ID of this component (e.g. 200 for IMU)
 * @param chan The MAVLink channel this message will be sent over
 * @param msg The MAVLink message to compress the data into
 * @param gnss_data C-struct to read the message contents from
 */
static inline uint16_t mavlink_msg_gnss_data_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg, const mavlink_gnss_data_t* gnss_data)
{
    return mavlink_msg_gnss_data_pack_chan(system_id, component_id, chan, msg, gnss_data->time, gnss_data->dt, gnss_data->lon, gnss_data->lat, gnss_data->height, gnss_data->east, gnss_data->north, gnss_data->up, gnss_data->eastVel, gnss_data->northVel, gnss_data->upVel, gnss_data->heading, gnss_data->pitch, gnss_data->tracktrue, gnss_data->vel, gnss_data->roll, gnss_data->pos_qual, gnss_data->heading_qual, gnss_data->satNum1, gnss_data->satNum2, gnss_data->gps_Num, gnss_data->bds_Num, gnss_data->glo_Num, gnss_data->pdop, gnss_data->hdop, gnss_data->vdop, gnss_data->year, gnss_data->month, gnss_data->day, gnss_data->hour, gnss_data->minute, gnss_data->second, gnss_data->data1, gnss_data->data2, gnss_data->data3, gnss_data->data4, gnss_data->data5, gnss_data->data6, gnss_data->data7, gnss_data->data8, gnss_data->data9, gnss_data->data10);
}

/**
 * @brief Send a gnss_data message
 * @param chan MAVLink channel to send the message
 *
 * @param time  time.
 * @param dt  dt.
 * @param lon  longitude.
 * @param lat  latitude.
 * @param height  height.
 * @param east  east.
 * @param north  north.
 * @param up  up.
 * @param eastVel  eastVel.
 * @param northVel  northVel.
 * @param upVel  upVel.
 * @param heading  heading.
 * @param pitch  pitch.
 * @param tracktrue  tracktrue.
 * @param vel  vel.
 * @param roll  roll.
 * @param pos_qual  pos_qual.
 * @param heading_qual  heading_qual.
 * @param satNum1  satNum1.
 * @param satNum2  satNum2.
 * @param gps_Num  gps_num.
 * @param bds_Num  gps_num.
 * @param glo_Num  gps_num.
 * @param pdop  pdop (0.5..99.9).
 * @param hdop   hdop (0.5..99.9).
 * @param vdop   vdop (0.5..99.9).
 * @param year   component.
 * @param month   component.
 * @param day   component.
 * @param hour   component.
 * @param minute   component.
 * @param second   component.
 * @param data1  data1
 * @param data2  data2
 * @param data3  data3
 * @param data4  data4
 * @param data5  data5
 * @param data6  data6
 * @param data7  data7
 * @param data8  data8
 * @param data9  data9
 * @param data10  data10
 */
#ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS

static inline void mavlink_msg_gnss_data_send(mavlink_channel_t chan, uint64_t time, uint32_t dt, float lon, float lat, float height, float east, float north, float up, float eastVel, float northVel, float upVel, float heading, float pitch, float tracktrue, float vel, float roll, int32_t pos_qual, int32_t heading_qual, int32_t satNum1, int32_t satNum2, int32_t gps_Num, int32_t bds_Num, int32_t glo_Num, float pdop, float hdop, float vdop, uint8_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second, float data1, float data2, float data3, float data4, float data5, float data6, float data7, float data8, float data9, float data10)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
    char buf[MAVLINK_MSG_ID_GNSS_DATA_LEN];
    _mav_put_uint64_t(buf, 0, time);
    _mav_put_uint32_t(buf, 8, dt);
    _mav_put_float(buf, 12, lon);
    _mav_put_float(buf, 16, lat);
    _mav_put_float(buf, 20, height);
    _mav_put_float(buf, 24, east);
    _mav_put_float(buf, 28, north);
    _mav_put_float(buf, 32, up);
    _mav_put_float(buf, 36, eastVel);
    _mav_put_float(buf, 40, northVel);
    _mav_put_float(buf, 44, upVel);
    _mav_put_float(buf, 48, heading);
    _mav_put_float(buf, 52, pitch);
    _mav_put_float(buf, 56, tracktrue);
    _mav_put_float(buf, 60, vel);
    _mav_put_float(buf, 64, roll);
    _mav_put_int32_t(buf, 68, pos_qual);
    _mav_put_int32_t(buf, 72, heading_qual);
    _mav_put_int32_t(buf, 76, satNum1);
    _mav_put_int32_t(buf, 80, satNum2);
    _mav_put_int32_t(buf, 84, gps_Num);
    _mav_put_int32_t(buf, 88, bds_Num);
    _mav_put_int32_t(buf, 92, glo_Num);
    _mav_put_float(buf, 96, pdop);
    _mav_put_float(buf, 100, hdop);
    _mav_put_float(buf, 104, vdop);
    _mav_put_float(buf, 108, data1);
    _mav_put_float(buf, 112, data2);
    _mav_put_float(buf, 116, data3);
    _mav_put_float(buf, 120, data4);
    _mav_put_float(buf, 124, data5);
    _mav_put_float(buf, 128, data6);
    _mav_put_float(buf, 132, data7);
    _mav_put_float(buf, 136, data8);
    _mav_put_float(buf, 140, data9);
    _mav_put_float(buf, 144, data10);
    _mav_put_uint8_t(buf, 148, year);
    _mav_put_uint8_t(buf, 149, month);
    _mav_put_uint8_t(buf, 150, day);
    _mav_put_uint8_t(buf, 151, hour);
    _mav_put_uint8_t(buf, 152, minute);
    _mav_put_uint8_t(buf, 153, second);

    _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_GNSS_DATA, buf, MAVLINK_MSG_ID_GNSS_DATA_MIN_LEN, MAVLINK_MSG_ID_GNSS_DATA_LEN, MAVLINK_MSG_ID_GNSS_DATA_CRC);
#else
    mavlink_gnss_data_t packet;
    packet.time = time;
    packet.dt = dt;
    packet.lon = lon;
    packet.lat = lat;
    packet.height = height;
    packet.east = east;
    packet.north = north;
    packet.up = up;
    packet.eastVel = eastVel;
    packet.northVel = northVel;
    packet.upVel = upVel;
    packet.heading = heading;
    packet.pitch = pitch;
    packet.tracktrue = tracktrue;
    packet.vel = vel;
    packet.roll = roll;
    packet.pos_qual = pos_qual;
    packet.heading_qual = heading_qual;
    packet.satNum1 = satNum1;
    packet.satNum2 = satNum2;
    packet.gps_Num = gps_Num;
    packet.bds_Num = bds_Num;
    packet.glo_Num = glo_Num;
    packet.pdop = pdop;
    packet.hdop = hdop;
    packet.vdop = vdop;
    packet.data1 = data1;
    packet.data2 = data2;
    packet.data3 = data3;
    packet.data4 = data4;
    packet.data5 = data5;
    packet.data6 = data6;
    packet.data7 = data7;
    packet.data8 = data8;
    packet.data9 = data9;
    packet.data10 = data10;
    packet.year = year;
    packet.month = month;
    packet.day = day;
    packet.hour = hour;
    packet.minute = minute;
    packet.second = second;

    _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_GNSS_DATA, (const char *)&packet, MAVLINK_MSG_ID_GNSS_DATA_MIN_LEN, MAVLINK_MSG_ID_GNSS_DATA_LEN, MAVLINK_MSG_ID_GNSS_DATA_CRC);
#endif
}

/**
 * @brief Send a gnss_data message
 * @param chan MAVLink channel to send the message
 * @param struct The MAVLink struct to serialize
 */
static inline void mavlink_msg_gnss_data_send_struct(mavlink_channel_t chan, const mavlink_gnss_data_t* gnss_data)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
    mavlink_msg_gnss_data_send(chan, gnss_data->time, gnss_data->dt, gnss_data->lon, gnss_data->lat, gnss_data->height, gnss_data->east, gnss_data->north, gnss_data->up, gnss_data->eastVel, gnss_data->northVel, gnss_data->upVel, gnss_data->heading, gnss_data->pitch, gnss_data->tracktrue, gnss_data->vel, gnss_data->roll, gnss_data->pos_qual, gnss_data->heading_qual, gnss_data->satNum1, gnss_data->satNum2, gnss_data->gps_Num, gnss_data->bds_Num, gnss_data->glo_Num, gnss_data->pdop, gnss_data->hdop, gnss_data->vdop, gnss_data->year, gnss_data->month, gnss_data->day, gnss_data->hour, gnss_data->minute, gnss_data->second, gnss_data->data1, gnss_data->data2, gnss_data->data3, gnss_data->data4, gnss_data->data5, gnss_data->data6, gnss_data->data7, gnss_data->data8, gnss_data->data9, gnss_data->data10);
#else
    _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_GNSS_DATA, (const char *)gnss_data, MAVLINK_MSG_ID_GNSS_DATA_MIN_LEN, MAVLINK_MSG_ID_GNSS_DATA_LEN, MAVLINK_MSG_ID_GNSS_DATA_CRC);
#endif
}

#if MAVLINK_MSG_ID_GNSS_DATA_LEN <= MAVLINK_MAX_PAYLOAD_LEN
/*
  This varient of _send() can be used to save stack space by re-using
  memory from the receive buffer.  The caller provides a
  mavlink_message_t which is the size of a full mavlink message. This
  is usually the receive buffer for the channel, and allows a reply to an
  incoming message with minimum stack space usage.
 */
static inline void mavlink_msg_gnss_data_send_buf(mavlink_message_t *msgbuf, mavlink_channel_t chan,  uint64_t time, uint32_t dt, float lon, float lat, float height, float east, float north, float up, float eastVel, float northVel, float upVel, float heading, float pitch, float tracktrue, float vel, float roll, int32_t pos_qual, int32_t heading_qual, int32_t satNum1, int32_t satNum2, int32_t gps_Num, int32_t bds_Num, int32_t glo_Num, float pdop, float hdop, float vdop, uint8_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second, float data1, float data2, float data3, float data4, float data5, float data6, float data7, float data8, float data9, float data10)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
    char *buf = (char *)msgbuf;
    _mav_put_uint64_t(buf, 0, time);
    _mav_put_uint32_t(buf, 8, dt);
    _mav_put_float(buf, 12, lon);
    _mav_put_float(buf, 16, lat);
    _mav_put_float(buf, 20, height);
    _mav_put_float(buf, 24, east);
    _mav_put_float(buf, 28, north);
    _mav_put_float(buf, 32, up);
    _mav_put_float(buf, 36, eastVel);
    _mav_put_float(buf, 40, northVel);
    _mav_put_float(buf, 44, upVel);
    _mav_put_float(buf, 48, heading);
    _mav_put_float(buf, 52, pitch);
    _mav_put_float(buf, 56, tracktrue);
    _mav_put_float(buf, 60, vel);
    _mav_put_float(buf, 64, roll);
    _mav_put_int32_t(buf, 68, pos_qual);
    _mav_put_int32_t(buf, 72, heading_qual);
    _mav_put_int32_t(buf, 76, satNum1);
    _mav_put_int32_t(buf, 80, satNum2);
    _mav_put_int32_t(buf, 84, gps_Num);
    _mav_put_int32_t(buf, 88, bds_Num);
    _mav_put_int32_t(buf, 92, glo_Num);
    _mav_put_float(buf, 96, pdop);
    _mav_put_float(buf, 100, hdop);
    _mav_put_float(buf, 104, vdop);
    _mav_put_float(buf, 108, data1);
    _mav_put_float(buf, 112, data2);
    _mav_put_float(buf, 116, data3);
    _mav_put_float(buf, 120, data4);
    _mav_put_float(buf, 124, data5);
    _mav_put_float(buf, 128, data6);
    _mav_put_float(buf, 132, data7);
    _mav_put_float(buf, 136, data8);
    _mav_put_float(buf, 140, data9);
    _mav_put_float(buf, 144, data10);
    _mav_put_uint8_t(buf, 148, year);
    _mav_put_uint8_t(buf, 149, month);
    _mav_put_uint8_t(buf, 150, day);
    _mav_put_uint8_t(buf, 151, hour);
    _mav_put_uint8_t(buf, 152, minute);
    _mav_put_uint8_t(buf, 153, second);

    _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_GNSS_DATA, buf, MAVLINK_MSG_ID_GNSS_DATA_MIN_LEN, MAVLINK_MSG_ID_GNSS_DATA_LEN, MAVLINK_MSG_ID_GNSS_DATA_CRC);
#else
    mavlink_gnss_data_t *packet = (mavlink_gnss_data_t *)msgbuf;
    packet->time = time;
    packet->dt = dt;
    packet->lon = lon;
    packet->lat = lat;
    packet->height = height;
    packet->east = east;
    packet->north = north;
    packet->up = up;
    packet->eastVel = eastVel;
    packet->northVel = northVel;
    packet->upVel = upVel;
    packet->heading = heading;
    packet->pitch = pitch;
    packet->tracktrue = tracktrue;
    packet->vel = vel;
    packet->roll = roll;
    packet->pos_qual = pos_qual;
    packet->heading_qual = heading_qual;
    packet->satNum1 = satNum1;
    packet->satNum2 = satNum2;
    packet->gps_Num = gps_Num;
    packet->bds_Num = bds_Num;
    packet->glo_Num = glo_Num;
    packet->pdop = pdop;
    packet->hdop = hdop;
    packet->vdop = vdop;
    packet->data1 = data1;
    packet->data2 = data2;
    packet->data3 = data3;
    packet->data4 = data4;
    packet->data5 = data5;
    packet->data6 = data6;
    packet->data7 = data7;
    packet->data8 = data8;
    packet->data9 = data9;
    packet->data10 = data10;
    packet->year = year;
    packet->month = month;
    packet->day = day;
    packet->hour = hour;
    packet->minute = minute;
    packet->second = second;

    _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_GNSS_DATA, (const char *)packet, MAVLINK_MSG_ID_GNSS_DATA_MIN_LEN, MAVLINK_MSG_ID_GNSS_DATA_LEN, MAVLINK_MSG_ID_GNSS_DATA_CRC);
#endif
}
#endif

#endif

// MESSAGE GNSS_DATA UNPACKING


/**
 * @brief Get field time from gnss_data message
 *
 * @return  time.
 */
static inline uint64_t mavlink_msg_gnss_data_get_time(const mavlink_message_t* msg)
{
    return _MAV_RETURN_uint64_t(msg,  0);
}

/**
 * @brief Get field dt from gnss_data message
 *
 * @return  dt.
 */
static inline uint32_t mavlink_msg_gnss_data_get_dt(const mavlink_message_t* msg)
{
    return _MAV_RETURN_uint32_t(msg,  8);
}

/**
 * @brief Get field lon from gnss_data message
 *
 * @return  longitude.
 */
static inline float mavlink_msg_gnss_data_get_lon(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  12);
}

/**
 * @brief Get field lat from gnss_data message
 *
 * @return  latitude.
 */
static inline float mavlink_msg_gnss_data_get_lat(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  16);
}

/**
 * @brief Get field height from gnss_data message
 *
 * @return  height.
 */
static inline float mavlink_msg_gnss_data_get_height(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  20);
}

/**
 * @brief Get field east from gnss_data message
 *
 * @return  east.
 */
static inline float mavlink_msg_gnss_data_get_east(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  24);
}

/**
 * @brief Get field north from gnss_data message
 *
 * @return  north.
 */
static inline float mavlink_msg_gnss_data_get_north(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  28);
}

/**
 * @brief Get field up from gnss_data message
 *
 * @return  up.
 */
static inline float mavlink_msg_gnss_data_get_up(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  32);
}

/**
 * @brief Get field eastVel from gnss_data message
 *
 * @return  eastVel.
 */
static inline float mavlink_msg_gnss_data_get_eastVel(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  36);
}

/**
 * @brief Get field northVel from gnss_data message
 *
 * @return  northVel.
 */
static inline float mavlink_msg_gnss_data_get_northVel(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  40);
}

/**
 * @brief Get field upVel from gnss_data message
 *
 * @return  upVel.
 */
static inline float mavlink_msg_gnss_data_get_upVel(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  44);
}

/**
 * @brief Get field heading from gnss_data message
 *
 * @return  heading.
 */
static inline float mavlink_msg_gnss_data_get_heading(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  48);
}

/**
 * @brief Get field pitch from gnss_data message
 *
 * @return  pitch.
 */
static inline float mavlink_msg_gnss_data_get_pitch(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  52);
}

/**
 * @brief Get field tracktrue from gnss_data message
 *
 * @return  tracktrue.
 */
static inline float mavlink_msg_gnss_data_get_tracktrue(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  56);
}

/**
 * @brief Get field vel from gnss_data message
 *
 * @return  vel.
 */
static inline float mavlink_msg_gnss_data_get_vel(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  60);
}

/**
 * @brief Get field roll from gnss_data message
 *
 * @return  roll.
 */
static inline float mavlink_msg_gnss_data_get_roll(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  64);
}

/**
 * @brief Get field pos_qual from gnss_data message
 *
 * @return  pos_qual.
 */
static inline int32_t mavlink_msg_gnss_data_get_pos_qual(const mavlink_message_t* msg)
{
    return _MAV_RETURN_int32_t(msg,  68);
}

/**
 * @brief Get field heading_qual from gnss_data message
 *
 * @return  heading_qual.
 */
static inline int32_t mavlink_msg_gnss_data_get_heading_qual(const mavlink_message_t* msg)
{
    return _MAV_RETURN_int32_t(msg,  72);
}

/**
 * @brief Get field satNum1 from gnss_data message
 *
 * @return  satNum1.
 */
static inline int32_t mavlink_msg_gnss_data_get_satNum1(const mavlink_message_t* msg)
{
    return _MAV_RETURN_int32_t(msg,  76);
}

/**
 * @brief Get field satNum2 from gnss_data message
 *
 * @return  satNum2.
 */
static inline int32_t mavlink_msg_gnss_data_get_satNum2(const mavlink_message_t* msg)
{
    return _MAV_RETURN_int32_t(msg,  80);
}

/**
 * @brief Get field gps_Num from gnss_data message
 *
 * @return  gps_num.
 */
static inline int32_t mavlink_msg_gnss_data_get_gps_Num(const mavlink_message_t* msg)
{
    return _MAV_RETURN_int32_t(msg,  84);
}

/**
 * @brief Get field bds_Num from gnss_data message
 *
 * @return  gps_num.
 */
static inline int32_t mavlink_msg_gnss_data_get_bds_Num(const mavlink_message_t* msg)
{
    return _MAV_RETURN_int32_t(msg,  88);
}

/**
 * @brief Get field glo_Num from gnss_data message
 *
 * @return  gps_num.
 */
static inline int32_t mavlink_msg_gnss_data_get_glo_Num(const mavlink_message_t* msg)
{
    return _MAV_RETURN_int32_t(msg,  92);
}

/**
 * @brief Get field pdop from gnss_data message
 *
 * @return  pdop (0.5..99.9).
 */
static inline float mavlink_msg_gnss_data_get_pdop(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  96);
}

/**
 * @brief Get field hdop from gnss_data message
 *
 * @return   hdop (0.5..99.9).
 */
static inline float mavlink_msg_gnss_data_get_hdop(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  100);
}

/**
 * @brief Get field vdop from gnss_data message
 *
 * @return   vdop (0.5..99.9).
 */
static inline float mavlink_msg_gnss_data_get_vdop(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  104);
}

/**
 * @brief Get field year from gnss_data message
 *
 * @return   component.
 */
static inline uint8_t mavlink_msg_gnss_data_get_year(const mavlink_message_t* msg)
{
    return _MAV_RETURN_uint8_t(msg,  148);
}

/**
 * @brief Get field month from gnss_data message
 *
 * @return   component.
 */
static inline uint8_t mavlink_msg_gnss_data_get_month(const mavlink_message_t* msg)
{
    return _MAV_RETURN_uint8_t(msg,  149);
}

/**
 * @brief Get field day from gnss_data message
 *
 * @return   component.
 */
static inline uint8_t mavlink_msg_gnss_data_get_day(const mavlink_message_t* msg)
{
    return _MAV_RETURN_uint8_t(msg,  150);
}

/**
 * @brief Get field hour from gnss_data message
 *
 * @return   component.
 */
static inline uint8_t mavlink_msg_gnss_data_get_hour(const mavlink_message_t* msg)
{
    return _MAV_RETURN_uint8_t(msg,  151);
}

/**
 * @brief Get field minute from gnss_data message
 *
 * @return   component.
 */
static inline uint8_t mavlink_msg_gnss_data_get_minute(const mavlink_message_t* msg)
{
    return _MAV_RETURN_uint8_t(msg,  152);
}

/**
 * @brief Get field second from gnss_data message
 *
 * @return   component.
 */
static inline uint8_t mavlink_msg_gnss_data_get_second(const mavlink_message_t* msg)
{
    return _MAV_RETURN_uint8_t(msg,  153);
}

/**
 * @brief Get field data1 from gnss_data message
 *
 * @return  data1
 */
static inline float mavlink_msg_gnss_data_get_data1(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  108);
}

/**
 * @brief Get field data2 from gnss_data message
 *
 * @return  data2
 */
static inline float mavlink_msg_gnss_data_get_data2(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  112);
}

/**
 * @brief Get field data3 from gnss_data message
 *
 * @return  data3
 */
static inline float mavlink_msg_gnss_data_get_data3(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  116);
}

/**
 * @brief Get field data4 from gnss_data message
 *
 * @return  data4
 */
static inline float mavlink_msg_gnss_data_get_data4(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  120);
}

/**
 * @brief Get field data5 from gnss_data message
 *
 * @return  data5
 */
static inline float mavlink_msg_gnss_data_get_data5(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  124);
}

/**
 * @brief Get field data6 from gnss_data message
 *
 * @return  data6
 */
static inline float mavlink_msg_gnss_data_get_data6(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  128);
}

/**
 * @brief Get field data7 from gnss_data message
 *
 * @return  data7
 */
static inline float mavlink_msg_gnss_data_get_data7(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  132);
}

/**
 * @brief Get field data8 from gnss_data message
 *
 * @return  data8
 */
static inline float mavlink_msg_gnss_data_get_data8(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  136);
}

/**
 * @brief Get field data9 from gnss_data message
 *
 * @return  data9
 */
static inline float mavlink_msg_gnss_data_get_data9(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  140);
}

/**
 * @brief Get field data10 from gnss_data message
 *
 * @return  data10
 */
static inline float mavlink_msg_gnss_data_get_data10(const mavlink_message_t* msg)
{
    return _MAV_RETURN_float(msg,  144);
}

/**
 * @brief Decode a gnss_data message into a struct
 *
 * @param msg The message to decode
 * @param gnss_data C-struct to decode the message contents into
 */
static inline void mavlink_msg_gnss_data_decode(const mavlink_message_t* msg, mavlink_gnss_data_t* gnss_data)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
    gnss_data->time = mavlink_msg_gnss_data_get_time(msg);
    gnss_data->dt = mavlink_msg_gnss_data_get_dt(msg);
    gnss_data->lon = mavlink_msg_gnss_data_get_lon(msg);
    gnss_data->lat = mavlink_msg_gnss_data_get_lat(msg);
    gnss_data->height = mavlink_msg_gnss_data_get_height(msg);
    gnss_data->east = mavlink_msg_gnss_data_get_east(msg);
    gnss_data->north = mavlink_msg_gnss_data_get_north(msg);
    gnss_data->up = mavlink_msg_gnss_data_get_up(msg);
    gnss_data->eastVel = mavlink_msg_gnss_data_get_eastVel(msg);
    gnss_data->northVel = mavlink_msg_gnss_data_get_northVel(msg);
    gnss_data->upVel = mavlink_msg_gnss_data_get_upVel(msg);
    gnss_data->heading = mavlink_msg_gnss_data_get_heading(msg);
    gnss_data->pitch = mavlink_msg_gnss_data_get_pitch(msg);
    gnss_data->tracktrue = mavlink_msg_gnss_data_get_tracktrue(msg);
    gnss_data->vel = mavlink_msg_gnss_data_get_vel(msg);
    gnss_data->roll = mavlink_msg_gnss_data_get_roll(msg);
    gnss_data->pos_qual = mavlink_msg_gnss_data_get_pos_qual(msg);
    gnss_data->heading_qual = mavlink_msg_gnss_data_get_heading_qual(msg);
    gnss_data->satNum1 = mavlink_msg_gnss_data_get_satNum1(msg);
    gnss_data->satNum2 = mavlink_msg_gnss_data_get_satNum2(msg);
    gnss_data->gps_Num = mavlink_msg_gnss_data_get_gps_Num(msg);
    gnss_data->bds_Num = mavlink_msg_gnss_data_get_bds_Num(msg);
    gnss_data->glo_Num = mavlink_msg_gnss_data_get_glo_Num(msg);
    gnss_data->pdop = mavlink_msg_gnss_data_get_pdop(msg);
    gnss_data->hdop = mavlink_msg_gnss_data_get_hdop(msg);
    gnss_data->vdop = mavlink_msg_gnss_data_get_vdop(msg);
    gnss_data->data1 = mavlink_msg_gnss_data_get_data1(msg);
    gnss_data->data2 = mavlink_msg_gnss_data_get_data2(msg);
    gnss_data->data3 = mavlink_msg_gnss_data_get_data3(msg);
    gnss_data->data4 = mavlink_msg_gnss_data_get_data4(msg);
    gnss_data->data5 = mavlink_msg_gnss_data_get_data5(msg);
    gnss_data->data6 = mavlink_msg_gnss_data_get_data6(msg);
    gnss_data->data7 = mavlink_msg_gnss_data_get_data7(msg);
    gnss_data->data8 = mavlink_msg_gnss_data_get_data8(msg);
    gnss_data->data9 = mavlink_msg_gnss_data_get_data9(msg);
    gnss_data->data10 = mavlink_msg_gnss_data_get_data10(msg);
    gnss_data->year = mavlink_msg_gnss_data_get_year(msg);
    gnss_data->month = mavlink_msg_gnss_data_get_month(msg);
    gnss_data->day = mavlink_msg_gnss_data_get_day(msg);
    gnss_data->hour = mavlink_msg_gnss_data_get_hour(msg);
    gnss_data->minute = mavlink_msg_gnss_data_get_minute(msg);
    gnss_data->second = mavlink_msg_gnss_data_get_second(msg);
#else
        uint8_t len = msg->len < MAVLINK_MSG_ID_GNSS_DATA_LEN? msg->len : MAVLINK_MSG_ID_GNSS_DATA_LEN;
        memset(gnss_data, 0, MAVLINK_MSG_ID_GNSS_DATA_LEN);
    memcpy(gnss_data, _MAV_PAYLOAD(msg), len);
#endif
}
